package com.wn.controller;

import com.wn.feigin.MemberFeignApi;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author yellow Docter
 * @date 2023 -02-21
 * @desc
 */
@RestController
@RequestMapping("feign")
public class FeignController {

    @Autowired
    private MemberFeignApi feignApi;

    @RequestMapping("{id}")
    public String helloFeign(@PathVariable("id") Integer id){
        return feignApi.getMemberById(id);
    }
}
